<?php 
	include("GetHostingPackagesID.php");
	include("GetHostingPackage.php");
	
	
if (!isset($_GET['id'])){
    
    echo'
  <div id="BodyMain">

  <p class="bodycopy">
  At J.P. Peach &amp; Associates we are interested in providing you with an excellent product 
  and the best service possible.  We have created a number of hosting packages that we think 
  will meet your needs. However, these packages can be fully customized, check out our 
  <a href="?section=webhosting&amp;page=webservice" class="SiteLink">Hosting Services</a> page for more details.
  </p>
   <ul>  ';

   $HostingIDlist = getIDs();
	//echo $HostingIDlist;
   foreach($HostingIDlist as $hostXid){

	$Package = getPackage($hostXid);
	
   echo ('<li>');
    if (isset($Package["URL"]) && isset($Package["Title"])) {
         echo('<a href="'.$Package["URL"].'" class="SiteLink">'.$Package["Title"].'</a><br />');
      if (isset($Package["Comment"])) { echo('<div class="bodycopy">'.$Package["Comment"]);
        if (isset($Package["SetupFee"])) { echo('<br />Setup fee: &nbsp; &nbsp; &nbsp;'.$Package["SetupFee"]); }
        if (isset($Package["MonthlyFee"])) { echo('<br />Monthly fee: &nbsp; &nbsp;'.$Package["MonthlyFee"].'<br />'); }
      echo('</div><br />');
      }
    }
   echo('</li>');
}

echo' </ul> </div> ';

}



else {
	include("GetServiceComment.php");
	include("GetServiceLabel.php");
	$PageID = $_GET['id'];

	$Package = getPackage($PageID);

	echo('  <div id="BodyMain">
	<h2 class = "header1">'.$Package["Title"].'</h2>
  <p class = "bodycopy"> 
   <span class = "header2">Setup Fee: &nbsp; &nbsp; &nbsp; </span>'.$Package["SetupFee"].'<br />
   <span class = "header2">Monthly Fee: &nbsp; &nbsp;</span>'.$Package["MonthlyFee"].'
  </p>

    <p class = "bodycopy">'.$Package["Description"].'</p> <br />  
      <div class = "bodycopy">
        This package includes the following services:         
          <ul>  ');
	
	$Explabels = explode(",", $Package["ServiceList"]);
	foreach ($Explabels as $xLabel) {
	$templabel = getLabel($xLabel, $PageID);
	echo'<li>'.$templabel.'</li>'; }
	echo' </ul> </div> ';

	$StarCounter = 1;
	foreach ($Explabels as $xcom) {
	$Komment = getComment($xcom);
	if (!($Komment == "")) {
	  echo'<p class = "FootNote"><sup>';
	  for ($i = 0; $i < $StarCounter; $i++) { echo'*'; }
	  echo'</sup>'.$Komment.'</p>';
	  $StarCounter++;
	  }
	}


echo'</div>';}


?>
